package com.student;

/**
 * 龚礼东
 * createtime: 2023/10/16
 * updatatime:
 */
public class AfromtoB {
    public static void main(String[] args) {
//        交换A，B位置
        int a = 10;
        int b = 8;

        int c = 0;
        System.out.println("交换前：");
        System.out.print("a=:");
        System.out.println(a);
        System.out.print("b=:");
        System.out.println(b);
        System.out.println();
        c = a;
        a = b;
        b = c;

        System.out.println("交换后：");
        System.out.print("a=:");
        System.out.println(a);
        System.out.print("b=:");
        System.out.println(b);
        System.out.println();
    }
}
